package com.hougong.im.entity;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 申请好友表
 * </p>
 *
 * @author lsz
 * @since 2018-08-25
 */
@TableName("apply_addfriend")
public class ApplyAddfriend implements Serializable {

    private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	private Long id;
    /**
     * 申请者
     */
	@TableField("from_id")
	private Long fromId;
    /**
     * 申请要添加的好友
     */
	@TableField("to_id")
	private Long toId;
    /**
     * 申请状态 -1不同意0等待中1同意
     */
	private Integer status;
    /**
     * 申请时间
     */
	@TableField("create_time")
	private Date createTime;
    /**
     * 结束时间
     */
	@TableField("end_time")
	private Date endTime;

	/**
	 * 接收方 1已读 0未读
	 */
	@TableField("if_to_read")
	private int ifToRead;
	/**
	 * 当接受方 操作后 ，发起方1已读 0未读
	 */
	@TableField("if_from_read")
	private int ifFromRead;

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Long getFromId() {
		return fromId;
	}

	public void setFromId(Long fromId) {
		this.fromId = fromId;
	}

	public Long getToId() {
		return toId;
	}

	public void setToId(Long toId) {
		this.toId = toId;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getEndTime() {
		return endTime;
	}

	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}

	public int getIfToRead() {
		return ifToRead;
	}

	public void setIfToRead(int ifToRead) {
		this.ifToRead = ifToRead;
	}

	public int getIfFromRead() {
		return ifFromRead;
	}

	public void setIfFromRead(int ifFromRead) {
		this.ifFromRead = ifFromRead;
	}

	@Override
	public String toString() {
		return "ApplyAddfriend{" +
				"id=" + id +
				", fromId=" + fromId +
				", toId=" + toId +
				", status=" + status +
				", createTime=" + createTime +
				", endTime=" + endTime +
				", ifToRead=" + ifToRead +
				", ifFromRead=" + ifFromRead +
				'}';
	}
}
